<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<title>QSculpt: geometry::Ray Class Reference</title>

<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />

<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>

</head>
<body>
<div id="top"><!-- do not remove this div! -->


<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  
  
  <td style="padding-left: 0.5em;">
   <div id="projectname">QSculpt
   &#160;<span id="projectnumber">0.0.1a</span>
   </div>
   
  </td>
  
  
  
 </tr>
 </tbody>
</table>
</div>

<!-- Generated by Doxygen 1.7.5.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="hierarchy.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
  <div id="nav-path" class="navpath">
    <ul>
      <li class="navelem"><a class="el" href="namespacegeometry.html">geometry</a>      </li>
      <li class="navelem"><a class="el" href="classgeometry_1_1_ray.html">Ray</a>      </li>
    </ul>
  </div>
</div>
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a>  </div>
  <div class="headertitle">
<div class="title">geometry::Ray Class Reference</div>  </div>
</div>
<div class="contents">
<!-- doxytag: class="geometry::Ray" -->
<p><a href="classgeometry_1_1_ray-members.html">List of all members.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgeometry_1_1_ray.html#a33fd5cf16cae332e23087539cd1f4908">Ray</a> (const Point3 &amp;o=DEFAULT_ORIGIN, const Vector3 &amp;d=DEFAULT_DIR)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgeometry_1_1_ray.html#a8403a6c56d9111b9ac8ac46a065c3c17">intersect</a> (const <a class="el" href="classgeometry_1_1_ray.html">Ray</a> &amp;ray, Point3 *p=NULL, float ep=DEFAULT_EPSILON) const </td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a5de111120cd3e0c972bcf462e20adfa2"></a><!-- doxytag: member="geometry::Ray::intersect" ref="a5de111120cd3e0c972bcf462e20adfa2" args="(const Plane &amp;plane, Point3 *p=NULL, float ep=DEFAULT_EPSILON) const " -->
float&#160;</td><td class="memItemRight" valign="bottom"><b>intersect</b> (const <a class="el" href="classgeometry_1_1_plane.html">Plane</a> &amp;plane, Point3 *p=NULL, float ep=DEFAULT_EPSILON) const </td></tr>
<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgeometry_1_1_ray.html#a8d73b8f67fcefcc5303540249f786867">intersect</a> (const Point3 &amp;point, Point3 *p=NULL, float ep=DEFAULT_EPSILON) const </td></tr>
<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgeometry_1_1_ray.html#a4a1c5bd7fe99c55e69a9ab4f3c72429b">intersect</a> (const <a class="el" href="classgeometry_1_1_sphere.html">Sphere</a> &amp;sphere, Point3 *p=NULL, float ep=DEFAULT_EPSILON) const </td></tr>
</table>
<hr/><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a33fd5cf16cae332e23087539cd1f4908"></a><!-- doxytag: member="geometry::Ray::Ray" ref="a33fd5cf16cae332e23087539cd1f4908" args="(const Point3 &amp;o=DEFAULT_ORIGIN, const Vector3 &amp;d=DEFAULT_DIR)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">geometry::Ray::Ray </td>
          <td>(</td>
          <td class="paramtype">const Point3 &amp;&#160;</td>
          <td class="paramname"><em>o</em> = <code>DEFAULT_ORIGIN</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const Vector3 &amp;&#160;</td>
          <td class="paramname"><em>d</em> = <code>DEFAULT_DIR</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Empty constructor. Origin is (0, 0, 0) and direction is (1, 0, 0) </p>

</div>
</div>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="a8403a6c56d9111b9ac8ac46a065c3c17"></a><!-- doxytag: member="geometry::Ray::intersect" ref="a8403a6c56d9111b9ac8ac46a065c3c17" args="(const Ray &amp;ray, Point3 *p=NULL, float ep=DEFAULT_EPSILON) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">float geometry::Ray::intersect </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classgeometry_1_1_ray.html">Ray</a> &amp;&#160;</td>
          <td class="paramname"><em>ray</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">Point3 *&#160;</td>
          <td class="paramname"><em>p</em> = <code>NULL</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float&#160;</td>
          <td class="paramname"><em>ep</em> = <code>DEFAULT_EPSILON</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Check if the ray intersects another ray and stores the intersection point in p.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">ray</td><td>ray to test intersection with. </td></tr>
    <tr><td class="paramname">p</td><td>an output paramter to store the point where the intersection happened. If null, not output is given. </td></tr>
    <tr><td class="paramname">ep</td><td>is the tolerance value to use to say if there is an intersection or not.</td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>a float value stating the time t in which the intersection ocurs </dd></dl>

</div>
</div>
<a class="anchor" id="a8d73b8f67fcefcc5303540249f786867"></a><!-- doxytag: member="geometry::Ray::intersect" ref="a8d73b8f67fcefcc5303540249f786867" args="(const Point3 &amp;point, Point3 *p=NULL, float ep=DEFAULT_EPSILON) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">float geometry::Ray::intersect </td>
          <td>(</td>
          <td class="paramtype">const Point3 &amp;&#160;</td>
          <td class="paramname"><em>point</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">Point3 *&#160;</td>
          <td class="paramname"><em>p</em> = <code>NULL</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float&#160;</td>
          <td class="paramname"><em>ep</em> = <code>DEFAULT_EPSILON</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Check if a point lies in a ray.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">point</td><td>point to test for. </td></tr>
    <tr><td class="paramname">p</td><td>point where the intersection is. For this overload, it is the same as point </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a4a1c5bd7fe99c55e69a9ab4f3c72429b"></a><!-- doxytag: member="geometry::Ray::intersect" ref="a4a1c5bd7fe99c55e69a9ab4f3c72429b" args="(const Sphere &amp;sphere, Point3 *p=NULL, float ep=DEFAULT_EPSILON) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">float geometry::Ray::intersect </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classgeometry_1_1_sphere.html">Sphere</a> &amp;&#160;</td>
          <td class="paramname"><em>sphere</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">Point3 *&#160;</td>
          <td class="paramname"><em>p</em> = <code>NULL</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float&#160;</td>
          <td class="paramname"><em>ep</em> = <code>DEFAULT_EPSILON</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Check if a ray intersects an sphere and stores the intersection point in p.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">sphere</td><td></td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li>engine/include/geometry/<a class="el" href="_ray_8h_source.html">Ray.h</a></li>
<li>engine/src/geometry/Ray.cpp</li>
</ul>
</div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Enumerator</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>



<hr class="footer"/><address class="footer"><small>
Generated on Thu May 31 2012 16:19:52 for QSculpt by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.7.5.1
</small></address>

</body>
</html>
